package com.clouddisk.system.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.clouddisk.common.core.domain.entity.UserFile;
import com.clouddisk.common.core.mapper.BaseMapperPlus;
import com.clouddisk.system.domain.FileSearch;
import com.clouddisk.system.domain.vo.file.FileListVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserFileMapper extends BaseMapperPlus<UserFileMapper,UserFile, UserFile> {

    List<UserFile> selectUserFileByLikeRightFilePath(@Param("filePath") String filePath, @Param("userId") long userId, @Param("fileDeptName") String fileDeptName);

    IPage<FileListVo> selectPageVo(Page<?> page, @Param("userFile") UserFile userFile, @Param("fileTypeId") Integer fileTypeId);

    Long selectStorageSizeByUserId(@Param("userId") Long userId, @Param("fileDeptName") String fileDeptName);

    FileSearch selectFileSearch(@Param("userFileId") String userFileId);
}
